#include <iostream>

using std::cout;
using std::endl;

class Point{
private:
    //无参构造函数
    Point()
    {

    }
    //(有参构造函数,eorror)是拷贝构造函数，虽然本质也是构造函数
    Point(const Point & rhs){

    }
    //赋值运算符
    Point & operator=(const Point &rhs){
        return *this;
    }

public:
    static Point & getInstance(){
        static Point s;
        cout << "static:" << &s << endl;
        return s;
    }


private:

};
void test(){

    Point & s1 = Point::getInstance();
    Point & s2 = Point::getInstance();
    cout << &s1 << endl;
    cout << &s2 << endl;

}

int main()
{
    test();
    return 0;
}

